Bump version to 3.20.0 and refactor binary tag handling#369
Merged
Conversation
- increment version from 3.19.0 to 3.20.0 in gradle.properties - change relocations from mutableMap to mutableList for better handling - add new methods for encoding and decoding BinaryTagHolder
Contributor
There was a problem hiding this comment.
Pull request overview
This PR bumps the project version to 3.20.0 (Gradle plugin to 2.0.8) and refactors Shadow relocation configuration to support per-relocation exclusion patterns, while also adding new NBT BinaryTag/BinaryTagHolder encode/decode utilities to the core API.
Changes:
- Added
BinaryTag.asTagHolder()plusBinaryTagHolder.decodeTag()/decodeCompoundTag()utilities for SNBT-based encode/decode. - Refactored Gradle plugin relocation handling to support exclusions (e.g., do not relocate
net.kyori.adventure.nbt.api.**). - Updated versioning and ABI dump to reflect the new public API surface.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| surf-api-gradle-plugin/src/main/kotlin/dev/slne/surf/api/gradle/platform/core/CoreSurfPlugin.kt | Switches Adventure NBT relocation to the new exclusion-capable relocation API. |
| surf-api-gradle-plugin/src/main/kotlin/dev/slne/surf/api/gradle/platform/common/CommonSurfPlugin.kt | Introduces Relocation model + relocatePackage(...) to support Shadow relocation excludes. |
| surf-api-gradle-plugin/build.gradle.kts | Bumps Gradle plugin version to 2.0.8. |
| surf-api-core/surf-api-core/src/main/kotlin/dev/slne/surf/api/core/nbt/nbt-extension.kt | Adds BinaryTagHolder encode/decode extension utilities to the core NBT API. |
| surf-api-core/surf-api-core/api/surf-api-core.api | Updates ABI dump to include the new NBT extension functions. |
| gradle.properties | Bumps overall project version to 3.20.0. |
| buildSrc/src/main/kotlin/core-convention.gradle.kts | Updates Shadow relocation to exclude net.kyori.adventure.nbt.api.** from relocation. |
Contributor
Author
|
@Mergifyio queue |
Contributor
Merge Queue Status
Waiting for
All conditions
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces several improvements and new features related to NBT (Named Binary Tag) handling and Gradle relocation logic, along with some version bumps. The main highlights are the addition of utility functions for encoding/decoding NBT tags, enhanced relocation logic that supports package exclusions, and corresponding configuration updates.
NBT Utilities:
nbt-extension.ktfor encoding aBinaryTagas aBinaryTagHolderand decoding aBinaryTagHolderback to aBinaryTagor specifically aCompoundBinaryTag. This provides a type-safe and convenient way to serialize and deserialize NBT data. [1] [2]Relocation Logic Enhancements:
CommonSurfPluginto support specifying exclusions when relocating packages, by introducing aRelocationdata class and updating related methods and usages. [1] [2] [3] [4]relocatePackagemethod fornet.kyori.adventure.nbt, excluding thenet.kyori.adventure.nbt.api.**package from relocation.core-convention.gradle.ktsto excludenet.kyori.adventure.nbt.api.**from relocation, preventing conflicts or issues with API classes.Version Bumps:
surf-api-coreversion to3.20.0andsurf-api-gradle-pluginversion to2.0.8to reflect the new features and changes. [1] [2]